<template>
  <div class="container">
  <head-title style="height:70px" @logout="logout"/>
  <div class="body-container" style="height:100%">
    <side-bar/>
    <container/>
  </div>
</div>
</template>

<script>
import head from '@/components/index/Header/index'
import side from '@/components/index/SideBar/index'
import body from '@/components/index/Container/index'
import LoginService from '@/service/login'
let loginService = new LoginService();
import { removeToken } from '@/utils/token'
export default {
  name:'Index',
  components:{
    HeadTitle:head,
    SideBar:side,
    Container:body
  },
  methods:{
    logout(){
      loginService.loginLogout().then(()=>{
        removeToken();
        this.$router.push({path:'/login'})
      });
    }
  }
}
</script>

<style lang="scss" scoped>
  .body-container{
    position: relative;
    width: 100%;
    min-width: 1300px;
    float: left;
  }
</style>